package com.ny.wlw;

public class Test02 {
    public static void main(String[] args) {
        Cat cat = new Cat();
        cat.setName("小黄");
        cat.setColor("黄色");
        System.out.println(cat.getName());
        System.out.println(cat.getColor());
        cat.play();

        Dog dog = new Dog();
        dog.setName("小黑");
        dog.setColor("黑色");
        System.out.println(dog.getName());
        System.out.println(dog.getColor());
        dog.play();
        System.out.println(dog.getAge());
        System.out.println(dog.a);

        dog.test();
    }
}
